﻿    module TypeMovement

    open System
    open Utilities
    open Microsoft.Xna.Framework
    open Microsoft.Xna.Framework.Content
    open Microsoft.Xna.Framework.Graphics
    open Math
    open SI


    let points = 100

    type circonferenza =
            {
                ySin :  List<float32>
                xCos :  List<float32>
            }
    
    let circonferenzaState = 
        {   
            ySin = [
                        for i=0 to points do
                            let l= (float i)/(float)points
                            let th = l*2.0*System.Math.PI
                            yield System.Math.Sin( th )/10.0|>float32
                    ]
            
            xCos = [
                        for i=0 to points do
                            let l= (float i)/(float)points
                            let th = l*2.0*System.Math.PI
                            yield System.Math.Cos( th )/10.0|>float32
                    ]
        }
    
    type Rodonea = //http://it.wikipedia.org/wiki/Sistema_di_coordinate_polari
        {
            ySin :  List<float32>
            xCos :  List<float32>
        }

    let RodoneaState = 
        {
            Rodonea.ySin = [
                                for i=0 to points do
                                    let l= (float i)/(float)points
                                    let th = l*2.0*System.Math.PI
                                    let r_th = 2.0*System.Math.Sin( 4.0*th )
                                    yield (r_th*System.Math.Sin( th ))/10.0|>float32
                            ]
            
            xCos =  [
                        for i=0 to points do
                            let l= (float i)/(float)points
                            let th = l*2.0*System.Math.PI
                            let r_th = 2.0*System.Math.Sin( 4.0*th )
                            yield (r_th*System.Math.Cos( th ))/10.0|>float32
                    ]

        }
